Skip to content

Add ability to send remote write 2.0 requests#124

Merged
saswatamcode merged 7 commits intoprometheus-community:mainfrom
saswatamcode:rw2.0
Feb 28, 2025
Merged

Add ability to send remote write 2.0 requests#124
saswatamcode merged 7 commits intoprometheus-community:mainfrom
saswatamcode:rw2.0

Conversation

@saswatamcode
Copy link
Collaborator

@saswatamcode saswatamcode commented Jan 19, 2025

Based on client_golang remote write 2.0 PR

metrics/write.go Outdated
Comment on lines +271 to +276
switch ts := any(tss).(type) {
case []*writev2.TimeSeries:
req = any(&writev2.Request{
Timeseries: ts[i:end],
Symbols: st.Symbols(),
}).(R)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this looks scary xD

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah was experimenting. Generics work, but result in super tricky code. I'll revert back to what I had initially

Copy link
Member

@bwplotka bwplotka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏽

@saswatamcode saswatamcode marked this pull request as ready for review February 24, 2025 08:07
Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Copy link
Member

@bwplotka bwplotka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Some comments

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Copy link
Member

@bwplotka bwplotka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! One naming bit, otherwise LGTM (feel free to merge after rename)

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
@saswatamcode saswatamcode merged commit 1eb48d9 into prometheus-community:main Feb 28, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants